<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
<script>

    var scoreObject = {
    "Tony": {
        "Math": 95,
        "English": 79,
        "Music": 68
    }, 
    "Simon": {
        "Math": 100,
        "English": 95,
        "Music": 98
    }, 
    "Annie": {
        "Math": 54,
        "English": 65,
        "Music": 88
    }
}
console.log(toObject(toJSON(scoreObject)))
//编写函数，实现将 JavaScript 对象转化为 JSON 字符串
function toJSON(obj){
  //your complement
  return JSON.stringify(obj)
}
//编写函数，实现将json字符串，转化为jS对象 
function toObject(json){
    return JSON.parse(json)
}
</script>
</html>